from django.core.files.storage import Storage
from django.utils.deconstruct import deconstructible

from meiduo_mall import settings


@deconstructible
class MyStorage(Storage):
    def __init__(self,fdfs_url=None):
        if not fdfs_url:
            fdfs_url = settings.FDFS_URL

        self.fdfs_url=fdfs_url



    def _open(self, name, mode='rb'):
        pass
    def _save(self, name, content):
        pass

    def url(self, name):




        return self.fdfs_url + name